package com.atguigu.gmall.model.product.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @Author:lyd
 **/
@Data
public class BaseEntity implements Serializable {

    /**
     * 编号
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    @TableField(value = "create_time",fill= FieldFill.INSERT)
    @JsonIgnore
    private Date createTime;


    @TableField(value = "update_time", fill = FieldFill.UPDATE)
    @JsonIgnore//表示这个字段无法序列化，不会展示给前端页面
    private Date updateTime;


    @TableField("is_deleted")
    @TableLogic
    private Byte isDeleted;
}
